#!/bin/bash
find . -name "*.class" -delete
find . -name "*.jar" -delete
find . -name "*.war" -delete
find . -name "*.iml" -delete
git checkout gradle/wrapper/gradle-wrapper.jar

find . -type d -name "target" -exec rm -r "{}" \;
find . -type d -name "bin" -exec rm -r "{}" \;
find . -type d -name "build" -exec rm -r "{}" \;

find . -type d -name "*-gen"  -exec rm -r "{}" \;
find . -type d -name "gen"  -exec rm -r "{}" \;
find . -type d -name "generated" -exec rm -r "{}" \;

find . -type d -name ".settings" -exec rm -r "{}" \;
find . -type d -name ".gradle" -exec rm -r "{}" \;
find . -type d -name ".idea" -exec rm -r "{}" \;
